<?php

use yii\db\Migration;
use yii\db\Schema;

class m170116_071635_add_pass_city extends Migration
{
    public function up()
    {
        $this->addColumn('{{template}}', 'pass_city', Schema::TYPE_STRING. "(128) NULL COMMENT '途经城市' ");
        $this->addColumn('{{template}}', 'days', Schema::TYPE_INTEGER. "(5) NULL COMMENT '天' ");
        $this->addColumn('{{template}}', 'nights', Schema::TYPE_INTEGER. "(5) NULL COMMENT '晚' ");
    }

    public function down()
    {
        echo "m170116_071635_add_pass_city cannot be reverted.\n";

        return false;
    }

    /*
    // Use safeUp/safeDown to run migration code within a transaction
    public function safeUp()
    {
    }

    public function safeDown()
    {
    }
    */
}
